﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin/AdminTemplate.Master" AutoEventWireup="true" CodeBehind="Users.aspx.cs" Inherits="HotelProject.Users" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="imageMap" runat="server">
    </asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server">
                </asp:ScriptManager>
 <div id="homePageContainer">
        <div id="homePageContent">
        <img name="admin" src="../../Images/background.jpg" width="838" height="632" border="0" id="admin" usemap="#default" alt="" />
        <div id="adminSubPage"> 
            <asp:GridView ID="GridView1" runat="server" AllowPaging="True" 
                AllowSorting="True" AutoGenerateColumns="False" 
                BackColor="LightGoldenrodYellow" BorderColor="Tan" BorderWidth="1px" 
                CellPadding="2" DataKeyNames="userName" DataSourceID="EntityDataSource1" 
                ForeColor="Black" GridLines="None" Width="816px">
                <AlternatingRowStyle BackColor="PaleGoldenrod" />
                <Columns>
                    <asp:CommandField ShowDeleteButton="True" ShowEditButton="True" />
                    <asp:BoundField DataField="userName" HeaderText="User Name" ReadOnly="True" 
                        SortExpression="userName" >
                    </asp:BoundField>
                    <asp:BoundField DataField="userFirstName" HeaderText="First Name" 
                        SortExpression="userFirstName" >
                    </asp:BoundField>
                    <asp:BoundField DataField="userLastName" HeaderText="Last Name" 
                        SortExpression="userLastName" >
                    </asp:BoundField>
                    <asp:BoundField DataField="userPassword" 
                        HeaderText="Password" SortExpression="userPassword" >
                    </asp:BoundField>
                    <asp:CheckBoxField DataField="isAdmin" HeaderText="Admin?" 
                        SortExpression="isAdmin" />
                </Columns>
                <FooterStyle BackColor="Tan" />
                <HeaderStyle BackColor="Tan" Font-Bold="True" />
                <PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" 
                    HorizontalAlign="Center" />
                <SelectedRowStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
                <SortedAscendingCellStyle BackColor="#FAFAE7" />
                <SortedAscendingHeaderStyle BackColor="#DAC09E" />
                <SortedDescendingCellStyle BackColor="#E1DB9C" />
                <SortedDescendingHeaderStyle BackColor="#C2A47B" />
            </asp:GridView>
            <asp:EntityDataSource ID="EntityDataSource1" runat="server" 
                ConnectionString="name=bshrews2Entities" 
                DefaultContainerName="bshrews2Entities" EnableDelete="True" 
                EnableFlattening="False" EnableInsert="True" EnableUpdate="True" 
                EntitySetName="registeredUsers">
                
            </asp:EntityDataSource>
            <div id="addUser">
                User Name <asp:TextBox ID="userNameTextBox" runat="server"></asp:TextBox>
                First Name <asp:TextBox ID="firstNameTextBox" runat="server"></asp:TextBox>
                    Last Name <asp:TextBox ID="lastNameTextBox" runat="server"></asp:TextBox>
                    <br />
                    Password <asp:TextBox ID="passwordTextBox" runat="server"></asp:TextBox>
                    Admin? <asp:CheckBox ID="adminCheckBox" runat="server" />
                    <asp:Button ID="createNewUserButton" runat="server" Text="Add User" 
                    onclick="createNewUserButton_Click" />
            </div>
            </div>
        </div>
       </div>
</asp:Content>
